# Maintainer: Florian Pritz <bluewind@xinu.at>

pkgname=perl-test-failwarnings
pkgver=0.008
pkgrel=6
pkgdesc='Add test failures if warnings are caught'
arch=(any)
license=(PerlArtistic GPL)
options=(!emptydirs)
depends=('perl>=5.8.1')
checkdepends=('perl-capture-tiny>=0.12')
url=https://metacpan.org/release/Test-FailWarnings
source=("https://search.cpan.org/CPAN/authors/id/D/DA/DAGOLDEN/Test-FailWarnings-$pkgver.tar.gz")
md5sums=(c03d51f550dbfd9945722ff7f4c32717)
sha512sums=(7bffcc18191326095d99ad01be6426f4d9d927f769a156318f9abfea67da6adfecb657bad89390740c9f531fe69c717afa1d250258eed63d127bf10cbbf2bd51)
_ddir="Test-FailWarnings-$pkgver"

build()
(
  cd "$srcdir/$_ddir"
  export PERL_MM_USE_DEFAULT=1 PERL_AUTOINSTALL=--skipdeps
  unset PERL5LIB PERL_MM_OPT
  /usr/bin/perl Makefile.PL
  make
)

check()
(
  cd "$srcdir/$_ddir"
  export PERL_MM_USE_DEFAULT=1
  unset PERL5LIB
  make test
)

package()
(
  cd "$srcdir/$_ddir"
  make install INSTALLDIRS=vendor DESTDIR="$pkgdir"
  find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
)

# Local Variables:
# mode: shell-script
# sh-basic-offset: 2
# End:
# vim:set ts=2 sw=2 et:
